    <include file="header" />
	<include file="header_nav" />
	<div class="row main-container">
		<include file="left_nav" />
		<div class="col-md-10 right-container">
			<div class="right-main-container">
				<div class="content-body" style="padding:20px;">
					<div class="post">
						<input type="hidden" id="type" name="type" value="{$list.type}" />
						<!---kind编辑器-->
						<div class="form-group">
							<label for="title" style="font-size:35px;">标题</label>
							<input id="title" name="title"  style="width:100%;height:45px;line-height:38px;font-size:28px;display:block;" placeholder="在这里输入标题" value="{$list.title}" {$list.disabled}/>
						</div>
						<div class="form-group">
						    <label for="title" style="font-size:35px;">内容</label>
							<textarea id="content" name="content"  style="width:100%;height:450px;display:block;" class="textarea">{$list.content}</textarea>
						</div>
						<script charset="utf-8" src="__PUBLIC__/js/kindeditor/kindeditor.js"></script>
						<script charset="utf-8" src="__PUBLIC__/js/kindeditor/lang/zh_CN.js"></script>
						<script>
							 var editor;
							 KindEditor.options.cssData = 'body { font-size: 16px; }';
							 KindEditor.ready(function(K) {
							  editor = K.create('#content',{
								//items:['preview','fontname', 'fontsize', '|', 'forecolor', 'hilitecolor', 'bold', '|', 'image', 'multiimage','flash', 'media', 'insertfile',  'hr', 'emoticons', 'link', 'unlink'],
								autoHeightMode : true,
								afterCreate : function() {
									this.loadPlugin('autoheight');
								}
								});
							});
							
							
					  </script>
					 <!---kind编辑器-->																																
					</div>
					
					<button type="submit" id="btn-submit" class="btn btn-info" style="height:52px;width:298px;font-size:22px;">立即保存</button>
				</div>


		    </div>
			<script type="text/javascript">
				
				$('#btn-submit').click(function () {
					var btn = $(this);
					var title = $('#title').val(); 
					var type = $('#type').val();
					var html = editor.html();
					html = $.trim(html);
					if(!html){ 
						remind('请填写内容','系统提示');
					}
					var article_id = "{$list.article_id}";
					$.post('__SELF__',{title:title,content:html,type:type},function(data){
						if(data.status == 1){
							remind(data.info,'系统提示');
						}else{
							remind(data.info,'系统提示');
							//$('#btn-submit').html('自动保存失败');//如果是input或者textarea 使用$('#fat-btn').val();
						}
						
					});     
				});

			</script>
			<include file="footer" />